<include file="Public:header"/>
角色名称： {$role.name} <a href="{:U('Rbac/access')}">返回</a> <a href="javascript:;" onclick="location.reload();">刷新</a><br/>
<form action="" method="post">
    <input type="submit" value="保存">
    <if condition="$isTop">
        <div class="span">
            <table>
                <tr>
                    <td colspan="5">项目</td>
                </tr>
                <tr>
                    <td>选择</td>
                    <td>标识</td>
                    <td>名称</td>
                    <td>标题</td>
                    <td>操作</td>
                </tr>
                <foreach name="nodes" item="node">
                    <tr>
                        <td>
                            <input type="checkbox" name="nodes[]" value="{$node.id}"
                            <if condition="$node['isAccess']">checked="checked"</if>
                            >
                            <input type="hidden" value="{$node.id}" name="nownodes[]" >
                        </td>
                        <td>{$node.id}</td>
                        <td>{$node.name}</td>
                        <td>{$node.title}</td>
                        <td>
                            <a href="{:U('/Access/role/id/'.$id.'/pid/'.$node['id'])}">子类</a>
                        </td>
                    </tr>
                </foreach>
            </table>
        </div>
    </if>
    <if condition="$isTwo">
        <div class="span">
            <present name="twoNodes">
                <table>
                    <tr>
                        <td colspan="5">模块<a href="{:U('/Access/role/id/'.$id)}">返回</a></td>
                    </tr>
                    <tr>
                        <td>选择</td>
                        <td>标识</td>
                        <td>名称</td>
                        <td>标题</td>
                        <td>操作</td>
                    </tr>
                    <foreach name="twoNodes" item="node">
                        <tr>
                            <td>
                                <input type="checkbox" name="nodes[]" value="{$node.id}"
                                <if condition="$node['isAccess']">checked="checked"</if>
                                >
                                <input type="hidden" value="{$node.id}" name="nownodes[]" >
                            </td>
                            <td>{$node.id}</td>
                            <td>{$node.name}</td>
                            <td>{$node.title}</td>
                            <td>
                                <a href="{:U('/Access/role/id/'.$id.'/pid/'.$pid.'/aid/'.$node['id'])}">子类</a>
                            </td>
                        </tr>
                    </foreach>
                </table>
            </present>
        </div>
    </if>
    <if condition="$isThree">
        <div class="span">
            <present name="threeNodes">
                <table>
                    <tr>
                        <td colspan="5">模块<a href="{:U('Access/role/id/'.$id.'/pid/'.$pid)}">返回</a></td>
                    </tr>
                    <tr>
                        <td>选择</td>
                        <td>标识</td>
                        <td>名称</td>
                        <td>标题</td>
                    </tr>
                    <foreach name="threeNodes" item="node">
                        <tr>
                            <td>
                                <input type="checkbox" name="nodes[]" value="{$node.id}"
                                <if condition="$node['isAccess']">checked="checked"</if>
                                >
                                <input type="hidden" value="{$node.id}" name="nownodes[]" >
                            </td>
                            <td>{$node.id}</td>
                            <td>{$node.name}</td>
                            <td>{$node.title}</td>
                        </tr>
                    </foreach>
                </table>
            </present>
        </div>
    </if>
</form>
<include file="Public:footer"/>